package org.corey.dev.voxiverse.gen;

import java.util.Random;

import org.corey.dev.voxiverse.block.Block;
import org.corey.dev.voxiverse.block.Block.BlockType;
import org.corey.dev.voxiverse.chunk.Chunk;


public class WaterGen {
	public WaterGen(){
		
	}
	
	public static void Generate(Block[][][] Blocks, Random r, int x, int y, int z){
		if (!(x==0) && !(x==Chunk.CHUNK_SIZE_X) && !(z ==0) && !(z==Chunk.CHUNK_SIZE_Z) && !(y==0) && !(y==Chunk.CHUNK_SIZE_Y)){
			if (Blocks[x-1][y][z].GetID() == 0 || Blocks[x][y-1][z].GetID() == 0 || Blocks[x][y][z-1].GetID() == 0){
				Blocks[x][y][z] = new Block(BlockType.BlockType_Water);
			}
		}
	}
}
